<#include "/macro/base.ftl" />


<div class="pageContent">
	<form method="post" action="${base}/sys/sysPermission/update" class="pageForm required-validate" onsubmit="return validateCallback(this, dialogAjaxDone);">
		<div class="pageFormContent" layoutH="58">
			<input name="id" value="${ bean.id?c!}" type="hidden"/>
				<p>
					<label>名称：</label>
					<input name="name"  class="required" type="text" size="20" value="${ (bean.name)!}" placeholder="请输入名称"/>
				</p>
				<p>
					<label>资源类型：</label>
			   	    <@dicRadio dicType="sys_permission_type" defaultValue="${(bean.resourceType)!}" name="resourceType"></@dicRadio>
				</p>
				<p>
					<label>资源路径：</label>
					<input name="url" type="text" size="20" value="${ (bean.url)!}" placeholder="请输入资源路径"/>
				</p>
				<p>
					<label>权限字符串：</label>
					<input name="permission" type="text" size="20" value="${ (bean.permission)!}" placeholder="权限字符"/>
				</p>
				<p>
					<label>父节点：</label>
					<select name="parentId">
						<option value="0">主节点</option>
						<#list list as record>
							<#if (record.parentId?? && record.parentId == 0)>
								<option value="${record.id?c}"<#if (record.id == bean.parentId)> selected="selected"</#if>>${record.name}</option>
								<#list list as record2>
									<#if (record2.parentId == record.id)>
										<option value="${record2.id?c}"<#if (record2.id == bean.parentId)> selected="selected"</#if>>&nbsp;&nbsp;&nbsp;&nbsp;|___${record2.name}</option>
										<#list list as record3>
											<#if (record3.parentId == record2.id)>
												<option value="${record3.id?c}" <#if (record3.id == bean.parentId)> selected="selected"</#if>>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;|___${record3.name}</option>
											</#if>
										</#list>
									</#if>
								</#list>
							</#if>
						</#list>
					</select>
				</p>
				<p>
					<label>是否可用：</label>
					<@dicRadio dicType="common_status" defaultValue="${(bean.available)!}" name="available"></@dicRadio>
				</p>
		</div>
		<div class="formBar">
			<ul>
				<li><div class="buttonActive"><div class="buttonContent"><button type="submit">保存</button></div></div></li>
				<li><div class="button"><div class="buttonContent"><button type="button" class="close">取消</button></div></div></li>
			</ul>
		</div>
	</form>
</div>
